//
//  DefineValue.h
//  CaoShi
//
//  Created by aa on 2018/4/20.
//  Copyright © 2018年 杨旭. All rights reserved.
//



#define YXWeakSelf __weak typeof(self) weakSelf = self;

/// 第一个参数是当下的控制器适配iOS11 一下的，第二个参数表示scrollview或子类
#define AdjustsScrollViewInsetNever(controller,view) if(@available(iOS 11.0, *)) {view.contentInsetAdjustmentBehavior = UIScrollViewContentInsetAdjustmentNever;} else if([controller isKindOfClass:[UIViewController class]]) {controller.automaticallyAdjustsScrollViewInsets = false;}

/*
 *是否为iPhoneX
 */
#define ISiPhoneX  ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(1125, 2436), [[UIScreen mainScreen] currentMode].size) : NO)

//获取项目版本号
#define BunldVersion  [[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleShortVersionString"];


//屏幕的宽度
#define kScreenWidth [[UIScreen mainScreen] bounds].size.width
//屏幕的高度
#define kScreenHeight [[UIScreen mainScreen] bounds].size.height

// tabBar高度
#define kTabBarHeight    49

// narBar高度
#define kNarBarHeight   iPhoneX ? 88.0f : 64.0f


// 定义全局颜色
#define color_globalColor [UIColor py_colorWithHexString:@"#ffdd00"]

// 定义标题颜色
#define color_titleColor [UIColor py_colorWithHexString:@"#5f3100"]

// 定义全局背景色
#define color_backColor [UIColor py_colorWithHexString:@"#f2f2f2"]

// 定义副标题颜色
#define color_textOne [UIColor py_colorWithHexString:@"#323232"]

// 定义副标题颜色
#define color_textTwo [UIColor py_colorWithHexString:@"#666666"]

// 定义副标题颜色
#define color_textThree [UIColor py_colorWithHexString:@"#999999"]

// 定义按钮颜色
#define color_coffee  [UIColor py_colorWithHexString:@"#5F3100"]

// 定义线条颜色
#define color_lineColor [UIColor py_colorWithHexString:@"#dddddd"]

// 定义蓝色
#define color_blueColor [UIColor py_colorWithHexString:@"#5cb4ea"]

// RGB
#define RGB(a, b, c) [UIColor colorWithRed:(a) / 255.0 green:(b) / 255.0 blue:(c) / 255.0 alpha:1.0]

// App根视图
#define AppRootViewController  [UIApplication sharedApplication].keyWindow.rootViewController

//请求数据成功
#define REQUESTDATASUCCESS [[NSString stringWithFormat:@"%@",[responseObject objectForKey:@"result"]] isEqualToString:@"success"]


//登录手机号
#define kPHONE @"phone"
//登录密码
#define kPASSWOED @"loginPassword"
//用户名
#define kRealName @"userName"
//用户头像
#define kHeaderPic @"pic"
//地址
#define kUserAddress @"address"
//用户设备标识
#define KAlias @"Alias"
//用户id
#define kUserID @"userId"





